interface ValidateCouponAPIResData {
  code: number
  msg: string
  time: string
  data: null
}

interface ValidateCouponAPIData {
  id: string
}

export function validateCouponAPI(data: ValidateCouponAPIData, token: string) {
  return httpInstance.post<ValidateCouponAPIResData, ValidateCouponAPIData>(
    '/api/coupon/cannelcoupon',
    data,
    { headers: { token } },
  )
}
